Ext.onReady(function() {

// Your code here
	var element= Ext.query("*[class=hi]");
	Ext.select('span.grip').on('click', function(element) {
		var sel=Ext.getDom(element);
		var firstchild=sel.target.parentNode.firstChild.textContent;
		var nextchild=sel.target.parentNode.nextSibling.textContent;
		var array2=nextchild.split(" ")
		var j = 0;
		for (var i=0; i < array2.length; i++) {
				if(array2[i]=="" || array2[i]==" "){
					j = i+1;			
				}else{
					break;
				}
			};
		sel.target.parentNode.firstChild.textContent=sel.target.parentNode.firstChild.textContent+" "+array2[j]
		var sel1 = sel.target.parentNode.nextSibling.textContent.replace(array2[j],"");
		sel.target.parentNode.nextSibling.textContent = sel1;
   });
});